package com.boot.seven.rabbitmq.header;

import com.boot.seven.constant.MqConstant;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.core.MessageBuilder;
import org.springframework.amqp.core.MessageProperties;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;
import java.util.Queue;

@Component
@Slf4j
public class ConsumerMsg {



    @RabbitListener(queues = "headerQueueB")
    public void msg1(String msg){

      log.info("bindingB消息获取:{}",msg);
    }

    @RabbitListener(queues = "headerQueue")
    public void msg2(String msg){

        log.info("binding消息获取:{}",msg);
    }
}
